<template>
  <div class="about">
    <h1>路由参数是: {{id}}</h1>
    <button @click="back">返回</button>
  </div>
</template>
<script setup>
  import { ref } from 'vue'
  import { useRoute, useRouter } from 'vue-router'
  let route = useRoute()
  let router = useRouter()
  let id = ref(route.query.id)
  // const back = () => router.back()
  const back = () => router.go(-1)
</script>
